package com.leyou.common.result;

import com.leyou.common.exception.LyException;
import lombok.Data;
import org.joda.time.DateTime;

import java.util.Date;

@Data
public class ExceptionResult {

    private Integer status;

    private String meaasge;

    private String timestamp;

    public ExceptionResult(LyException e){
        this.status = e.getStatus();
        this.meaasge = e.getMessage();
        this.timestamp = DateTime.now().toString("yyyy-MM-dd hh:mm:ss");
    }

}
